package com.xielx.httpclikent.bean;

import java.io.Serializable;
import java.util.Map;

public class MyHttpResponse implements Serializable {
    private static final long serialVersionUID = 7305179889589897095L;
    private int httpCode;
    private byte[] content;
    private Map<String,String> header;

    public MyHttpResponse(int httpCode) {
        this.httpCode = httpCode;
    }

    public MyHttpResponse(int httpCode, byte[] content) {
        this.httpCode = httpCode;
        this.content = content;
    }

    public MyHttpResponse(int httpCode, byte[] content, Map<String, String> header) {
        this.httpCode = httpCode;
        this.content = content;
        this.header = header;
    }

    public int getHttpCode() {
        return httpCode;
    }

    public void setHttpCode(int httpCode) {
        this.httpCode = httpCode;
    }

    public byte[] getContent() {
        return content;
    }

    public void setContent(byte[] content) {
        this.content = content;
    }

    public Map<String, String> getHeader() {
        return header;
    }

    public void setHeader(Map<String, String> header) {
        this.header = header;
    }

    public String getStrData() {
        return new String(getContent());
    }
}
